// 证据类型枚举
export enum EvidenceType {
  PHYSICAL = '物证',
  DOCUMENTARY = '书证',
  TESTIMONIAL = '言证',
  DIGITAL = '电子证据'
}

// 证据值对象（不可变）
export class EvidenceValue {
  constructor(
    public readonly id: string,
    public readonly caseId: string,
    public readonly name: string,
    public readonly type: EvidenceType,
    public readonly description: string,
    public readonly locationFound: string,
    public readonly collectedBy: string,
    public readonly collectionTime: string,
    public readonly analysisReport: string = '',
    public readonly isValid: boolean = true
  ) {}
  
  // 创建新的证据值对象（不可变特性）
  withAnalysisReport(analysisReport: string): EvidenceValue {
    return new EvidenceValue(
      this.id,
      this.caseId,
      this.name,
      this.type,
      this.description,
      this.locationFound,
      this.collectedBy,
      this.collectionTime,
      analysisReport,
      this.isValid
    );
  }
}
